<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8" />
		<title></title>
	</head>
	<style type="text/css">
		#introduce{
			display: flex;
			align-items: center;
		}
		#rightWay{
			display: flex;
			justify-content: flex-end;
		}
	</style>
	<body>
		<h3>工作简历</h3>
		<div id="">
			<hr >
			<div id="total">
				<div>
					公司名称：<input type="text" name="" id="" value="" />
					职位：<input type="text" name="" id="" value="" /> 
					<a href="javascript:;" id="delete">删除简历</a><br/><br/>
					<div id="introduce">
						自我介绍：<textarea rows="8" cols="50"></textarea>
					</div>
					<hr >
				</div>
			</div>
			<div id="rightWay">
				<a href="javascript:;" id = "add">添加简历</a>
			</div>
		</div>
	</body>
	<script type="text/javascript">
		window.onload = function(){
			var total = document.getElementById("total");
			
			var newDiv = document.createElement("div");
			newDiv.innerHTML = total.innerHTML;
			console.log(newDiv.innerHTML);
			
			var a = document.getElementById("delete");
			a.onclick = function(){
				total.removeChild(a.parentElement);	
			}
			
			var add = document.getElementById("add");
			add.onclick = function(){
				total.appendChild(newDiv);
			}
		}
	</script>
</html>
